home *** CD-ROM | disk | FTP | other *** search
Text File | 1997-06-28 | 704 b | 38 lines | [TEXT/CWIE] |
- // CompileStatistics.h
-
- #ifndef CompileStatistics_h
- #define CompileStatistics_h
-
- #ifndef FileStatistics_h
- #include "FileStatistics.h"
- #endif
- #ifndef RedBlackLinkTree_h
- #include "RedBlackLinkTree.h"
- #endif
-
- class CompileStatistics
- {
- private:
- RedBlackLinkTree< ConstPString, FileStatistics > tree;
- uint32 lines;
- uint32 files;
-
- FileStatistics *lastLookup; // mutable
-
- FileStatistics *Lookup( ConstPString ) const;
-
- public:
- CompileStatistics();
- ~CompileStatistics();
-
- uint32 AverageLines() const;
-
- bool Known( ConstPString name ) const;
- uint32 FileLines( ConstPString ) const;
-
- void AddFile( ConstPString name );
- void SetFileLines( ConstPString, uint32 );
- };
-
- #endif
-